//
//  MineFootView.m
//  HappyRent
//
//  Created by CoderYee on 2017/3/29.
//  Copyright © 2017年 内圈科技. All rights reserved.
//

#import "MineFootView.h"

@implementation MineFootView

-(instancetype)initWithFrame:(CGRect)frame{
    
    if (self=[super initWithFrame:frame]) {
        
        [self addOwnView];
    }
    
    return self;
}
-(void)addOwnView{
   
    UIImageView *imageView=[[UIImageView alloc] initWithFrame:CGRectZero];
    imageView.contentMode=UIViewContentModeScaleAspectFit;
    imageView.clipsToBounds=YES;
    [imageView setImage:[[UIImage imageNamed:@"tabbar_setting"] imageWithGradientTintColor:kNavBarThemeColor]];
    [self addSubview:imageView];
    
    [imageView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.centerY.equalTo(self);
        make.left.equalTo(self).with.offset(15);
    }];
    UILabel *textLable=[[UILabel alloc] initWithFrame:CGRectZero];
    textLable.font=[UIFont systemFontOfSize:14];
    textLable.textColor=kGrayColor;
    textLable.text=@"切换到卖家版";
    [self addSubview:textLable];
    [textLable mas_makeConstraints:^(MASConstraintMaker *make) {
        make.centerY.equalTo(self);
        make.left.equalTo(imageView.mas_right).offset(15);
    }];
    
    UIView *lineView=[[UIView alloc] initWithFrame:CGRectZero];
    [lineView setBackgroundColor:kNavBarThemeColor];
    [self addSubview:lineView];
    [lineView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.right.top.equalTo(self);
        make.height.mas_equalTo(0.5);
    }];
    

}

@end
